package cn.edu.neu.vmmigeval.cloud.config;

import cn.edu.neu.vmmigeval.cloud.entity.Host;
import cn.edu.neu.vmmigeval.cloud.entity.Vm;

import java.util.List;

/**
 * Created by yfwz100 on 16/2/25.
 */
public class Migration {


    private int id;
    //从哪台host上进行的迁移
    private Host srcHost;

    //那些虚拟机需要被迁移
    private List<Vm> vms;

    //迁移到哪
    private Host destHost;

    //需要几个时钟周期
    private int clocks;

    //现在是第几个始终周期
    private int nowClock;
    //迁移是否完成
    private boolean end = false;

    //迁移工作的类型
    private String type;

    public Migration() {
    }

    public Migration(int id, Host srcHost, List<Vm> vms, Host destHost,
                     int clocks, int nowClock, boolean end, String type) {
        super();
        this.id = id;
        this.srcHost = srcHost;
        this.vms = vms;
        this.destHost = destHost;
        this.clocks = clocks;
        this.nowClock = nowClock;
        this.end = end;
        this.type = type;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public Host getSrcHost() {
        return srcHost;
    }

    public void setSrcHost(Host srcHost) {
        this.srcHost = srcHost;
    }

    public List<Vm> getVms() {
        return vms;
    }

    public void setVms(List<Vm> vms) {
        this.vms = vms;
    }

    public Host getDestHost() {
        return destHost;
    }

    public void setDestHost(Host destHost) {
        this.destHost = destHost;
    }

    public int getClocks() {
        return clocks;
    }

    public void setClocks(int clocks) {
        this.clocks = clocks;
    }

    public int getNowClock() {
        return nowClock;
    }

    public void setNowClock(int nowClock) {
        this.nowClock = nowClock;
    }

    public boolean isEnd() {
        return end;
    }

    public void setEnd(boolean end) {
        this.end = end;
    }


    public String getType() {
        return type;
    }


    public void setType(String type) {
        this.type = type;
    }


}
